package homeWork.SOC4.mission_extra;

/**
 * 汽车实体描述类
 */
public class Vehicle {

    //属性
    protected String type;
    protected String brand;
    protected int engineNum;
    protected String color;

    //行为
    public Vehicle() {
    }

    public Vehicle(String type, String brand, int engineNum, String color) {
        this.type = type;
        this.brand = brand;
        this.engineNum = engineNum;
        this.color = color;
    }

    public void start(){
        System.out.println("启动(汽车)");
    }

    public void accelerate(){
        System.out.println("加速(汽车)");
    }

    public void brake(){
        System.out.println("刹车(汽车)");
    }

    public void stop(){
        System.out.println("停车(汽车)");
    }
}
